package com.topvision.idcard;

import android.content.Context;
import android.graphics.Color;
import android.widget.TextView;
import android.widget.Toast;

/**
 * Created by lucy on 2017/5/19.
 */

public class Utils {
    private static Toast toast;
    public static final void showTips(final Context context, String text) {
        if (toast == null) {
            toast = Toast.makeText(context, "", Toast.LENGTH_SHORT);
        }
        TextView tv = new TextView(context);
        tv.setText(text);
        tv.setTextColor(Color.RED);
        tv.setTextSize(30);
        toast.setView(tv);
        toast.show();
    }
}
